package com.ruoyi.chat.domain;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 用户会话聊天记录对象 chat_record
 * 
 * @author twilight
 * @date 2025-08-04
 */
public class ChatRecord extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 主键ID */
    private Long id;

    /** 会话ID */
    @Excel(name = "会话ID")
    private String sessionId;

    /** 发送者 */
    @Excel(name = "发送者")
    private String sender;

    /** 接收者 */
    @Excel(name = "接收者")
    private String receive;

    /** 聊天内容 */
    @Excel(name = "聊天内容")
    private String content;

    /** 发送类型（1：文本；2：图片） */
    @Excel(name = "发送类型", readConverterExp = "1=：文本；2：图片")
    private String contentType;

    /** 此轮模型解析的参数 */
    @Excel(name = "此轮模型解析的参数")
    private String llmParams;

    /** 模型交互的历史消息 */
    @Excel(name = "模型交互的历史消息")
    private String history;

    /** 流程id */
    @Excel(name = "流程id")
    private Long flowId;

    /** 是否作为大模型上下文（1是 0否） */
    @Excel(name = "是否作为大模型上下文", readConverterExp = "1=是,0=否")
    private String bigModel;

    /** 用户角色: user 用户;assistant 对话助手 */
    @Excel(name = "用户角色: user 用户;assistant 对话助手")
    private String roleName;

    /** 大模型问答轮次 */
    @Excel(name = "大模型问答轮次")
    private Long round;

    /** 模型种类：（0：qianfan, 1:qianwen） */
    @Excel(name = "模型种类：", readConverterExp = "0=：qianfan,,1=:qianwen")
    private Long llmType;

    /** 状态（0正常 1停用） */
    @Excel(name = "状态", readConverterExp = "0=正常,1=停用")
    private String status;

    /** 删除标志（0代表存在 2代表删除） */
    private String delFlag;

    public void setId(Long id) 
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }

    public void setSessionId(String sessionId) 
    {
        this.sessionId = sessionId;
    }

    public String getSessionId() 
    {
        return sessionId;
    }

    public void setSender(String sender) 
    {
        this.sender = sender;
    }

    public String getSender() 
    {
        return sender;
    }

    public void setReceive(String receive) 
    {
        this.receive = receive;
    }

    public String getReceive() 
    {
        return receive;
    }

    public void setContent(String content) 
    {
        this.content = content;
    }

    public String getContent() 
    {
        return content;
    }

    public void setContentType(String contentType) 
    {
        this.contentType = contentType;
    }

    public String getContentType() 
    {
        return contentType;
    }

    public void setLlmParams(String llmParams) 
    {
        this.llmParams = llmParams;
    }

    public String getLlmParams() 
    {
        return llmParams;
    }

    public void setHistory(String history) 
    {
        this.history = history;
    }

    public String getHistory() 
    {
        return history;
    }

    public void setFlowId(Long flowId) 
    {
        this.flowId = flowId;
    }

    public Long getFlowId() 
    {
        return flowId;
    }

    public void setBigModel(String bigModel) 
    {
        this.bigModel = bigModel;
    }

    public String getBigModel() 
    {
        return bigModel;
    }

    public void setRoleName(String roleName) 
    {
        this.roleName = roleName;
    }

    public String getRoleName() 
    {
        return roleName;
    }

    public void setRound(Long round) 
    {
        this.round = round;
    }

    public Long getRound() 
    {
        return round;
    }

    public void setLlmType(Long llmType) 
    {
        this.llmType = llmType;
    }

    public Long getLlmType() 
    {
        return llmType;
    }

    public void setStatus(String status) 
    {
        this.status = status;
    }

    public String getStatus() 
    {
        return status;
    }

    public void setDelFlag(String delFlag) 
    {
        this.delFlag = delFlag;
    }

    public String getDelFlag() 
    {
        return delFlag;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("sessionId", getSessionId())
            .append("sender", getSender())
            .append("receive", getReceive())
            .append("content", getContent())
            .append("contentType", getContentType())
            .append("llmParams", getLlmParams())
            .append("history", getHistory())
            .append("flowId", getFlowId())
            .append("bigModel", getBigModel())
            .append("roleName", getRoleName())
            .append("round", getRound())
            .append("llmType", getLlmType())
            .append("status", getStatus())
            .append("delFlag", getDelFlag())
            .append("createBy", getCreateBy())
            .append("createTime", getCreateTime())
            .append("updateBy", getUpdateBy())
            .append("updateTime", getUpdateTime())
            .append("remark", getRemark())
            .toString();
    }
}
